package com.lengchangjing.BehavioralPatterns.VisitorPattern;

public class ConcreteVisitorB implements Visitor {
    @Override
    public void visit(ConcreteElementA element) {
        System.out.println(this.getClass().getSimpleName() + " visit " + element.getClass().getSimpleName());
    }

    @Override
    public void visit(ConcreteElementB element) {
        System.out.println(this.getClass().getSimpleName() + " visit " + element.getClass().getSimpleName());
    }
}
